<?php

//$yii_app = dirname(__FILE__) . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..';
//$current_cwd = getcwd();
//chdir($yii_app);
//$curr = getcwd();
//$yii = $curr . '/../yii/framework/yii.php';
//$config = $curr . '/protected/config/main.php';
//defined('YII_DEBUG') or define('YII_DEBUG', true);
//defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL', 3);
//require_once($yii);
//Yii::createWebApplication($config);
//$uploadURL = Yii::app()->baseUrl
//        . '/..'
//        . Yii::app()->params['fileDownloadPath'];
//        $uploadDir = dirname(__FILE__) . DIRECTORY_SEPARATOR
//        . '..' . DIRECTORY_SEPARATOR // out of integration
//        . '..' // out of kcfinder
//        . Yii::app()->params['fileDownloadPath'];
//
//$session = new CHttpSession;
//$session->setSavePath(Yii::app()->session->savePath);
//$session->open();
//$session['KCFINDER'] = array();
//$session['KCFINDER'] = array(
//    'disabled' => !UserIdentity::canBrowseServer(),
//    'uploadURL' => $uploadURL,
//    'uploadDir' => $uploadDir,
//);
//// then back to our path
//chdir($current_cwd);
//
//spl_autoload_unregister(array('YiiBase', 'autoload'));
//spl_autoload_register('__autoload');
//spl_autoload_register(array('YiiBase', 'autoload'));
?>